<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>
<body>
    <script>
        //1.创建一个对象
        const request = new XMLHttpRequest();
        //2.新创建一个请求
        request.open("GET","http://www.biwuit.cn/spboot/userLoginGetRequest?username=admin&password=66666")
        //3.发送
        request.send()
        //4.
        request.onreadystatechange = function(){
            console.log(request.status)         //返回200
            console.log(request.statusText)     //空？？？
            // console.log(request.responseText)
            console.log(request.response)       //好像也是返回内容
            console.log(request.readyState)     //返回状态 1 2 3 4
        }
    </script>
</body>
</html>